package com.ek.distmpl.dao.mapper;

import com.ek.distmpl.dao.model.Schedule;
import com.ek.distmpl.dao.model.ScheduleExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface ScheduleMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @SelectProvider(type=ScheduleSqlProvider.class, method="countByExample")
    long countByExample(ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @DeleteProvider(type=ScheduleSqlProvider.class, method="deleteByExample")
    int deleteByExample(ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @Delete({
        "delete from schedule",
        "where schedule_sid = #{scheduleSid,jdbcType=CHAR}"
    })
    int deleteByPrimaryKey(String scheduleSid);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @Insert({
        "insert into schedule (schedule_sid, schedule_uid, ",
        "schedule_cid, schedule_status, ",
        "stime)",
        "values (#{scheduleSid,jdbcType=CHAR}, #{scheduleUid,jdbcType=CHAR}, ",
        "#{scheduleCid,jdbcType=CHAR}, #{scheduleStatus,jdbcType=INTEGER}, ",
        "#{stime,jdbcType=LONGVARCHAR})"
    })
    int insert(Schedule record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @InsertProvider(type=ScheduleSqlProvider.class, method="insertSelective")
    int insertSelective(Schedule record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @SelectProvider(type=ScheduleSqlProvider.class, method="selectByExampleWithBLOBs")
    @Results({
        @Result(column="schedule_sid", property="scheduleSid", jdbcType=JdbcType.CHAR, id=true),
        @Result(column="schedule_uid", property="scheduleUid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_cid", property="scheduleCid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_status", property="scheduleStatus", jdbcType=JdbcType.INTEGER),
        @Result(column="stime", property="stime", jdbcType=JdbcType.LONGVARCHAR)
    })
    List<Schedule> selectByExampleWithBLOBs(ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @SelectProvider(type=ScheduleSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="schedule_sid", property="scheduleSid", jdbcType=JdbcType.CHAR, id=true),
        @Result(column="schedule_uid", property="scheduleUid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_cid", property="scheduleCid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_status", property="scheduleStatus", jdbcType=JdbcType.INTEGER)
    })
    List<Schedule> selectByExample(ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @Select({
        "select",
        "schedule_sid, schedule_uid, schedule_cid, schedule_status, stime",
        "from schedule",
        "where schedule_sid = #{scheduleSid,jdbcType=CHAR}"
    })
    @Results({
        @Result(column="schedule_sid", property="scheduleSid", jdbcType=JdbcType.CHAR, id=true),
        @Result(column="schedule_uid", property="scheduleUid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_cid", property="scheduleCid", jdbcType=JdbcType.CHAR),
        @Result(column="schedule_status", property="scheduleStatus", jdbcType=JdbcType.INTEGER),
        @Result(column="stime", property="stime", jdbcType=JdbcType.LONGVARCHAR)
    })
    Schedule selectByPrimaryKey(String scheduleSid);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @UpdateProvider(type=ScheduleSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") Schedule record, @Param("example") ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @UpdateProvider(type=ScheduleSqlProvider.class, method="updateByExampleWithBLOBs")
    int updateByExampleWithBLOBs(@Param("record") Schedule record, @Param("example") ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @UpdateProvider(type=ScheduleSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") Schedule record, @Param("example") ScheduleExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @UpdateProvider(type=ScheduleSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(Schedule record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @Update({
        "update schedule",
        "set schedule_uid = #{scheduleUid,jdbcType=CHAR},",
          "schedule_cid = #{scheduleCid,jdbcType=CHAR},",
          "schedule_status = #{scheduleStatus,jdbcType=INTEGER},",
          "stime = #{stime,jdbcType=LONGVARCHAR}",
        "where schedule_sid = #{scheduleSid,jdbcType=CHAR}"
    })
    int updateByPrimaryKeyWithBLOBs(Schedule record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table schedule
     *
     * @mbg.generated Fri Mar 29 15:10:48 CST 2019
     */
    @Update({
        "update schedule",
        "set schedule_uid = #{scheduleUid,jdbcType=CHAR},",
          "schedule_cid = #{scheduleCid,jdbcType=CHAR},",
          "schedule_status = #{scheduleStatus,jdbcType=INTEGER}",
        "where schedule_sid = #{scheduleSid,jdbcType=CHAR}"
    })
    int updateByPrimaryKey(Schedule record);
}